// version 项目
 # include <windows.h>
 # include <iostream>
int main()
 {
 DWORD dwIdThis = :: GetCurrentProcessId() ;
 DWORD dwVerReq = :: GetProcessVersion(dwIdThis) ;
 WORD wMajorReq =( (WORD) dwVerReq > 16) ;
 WORD wMinorReq = ((WORD) dwVerReq & 0xffff) ;
 std :: cout << "Process ID: " << dwIdThis
 << ", requires OS: " << wMajorReq << wMinorReq << std :: endl ;
 OSVERSIONINFOEX osvix;
 :: ZeroMemory(&osvix, sizeof(osvix) ) ;
 osvix.dwOSVersionInfoSize = sizeof(osvix) ;
 :: GetVersionEx(reinterpret_cast < LPOSVERSIONINFO > (&osvix) ) ;
 std :: cout << "Running on OS: " << osvix.dwMajorVersion << "."
 << osvix.dwMinorVersion << std :: endl;
 if (osvix.dwPlatformId == VER_PLATFORM_WIN32_NT &&
 osvix.dwMajorVersion >= 5)
 {
 :: SetPriorityClass(
 :: GetCurrentProcess() ,
 HIGH_PRIORITY_CLASS) ;
 std :: cout << "Task Manager should now now indicate this"
 "process is high priority．" << std :: endl;
 }
 system("pause");
 return 0;
 }